package com.bean.library;

import java.util.ArrayList;
import java.util.List;

public class Paper {
	String paperName;
	ArrayList<Subject> subList=null;
	
	
	public boolean setPaperName(String paperName){
		if(paperName.equals(null))return false;
		this.paperName = paperName;
		return true;
	}
	public Paper(){
		
	}
	public String getPaperName(){
		return this.paperName;
	}
	public boolean addSubject(Subject subject){
		if(this.subList==null){
			this.subList = new ArrayList<Subject>();
		}
		return this.subList.add(subject);
	}
	public boolean setSubjectList(ArrayList<Subject> list){
		if(this.subList!=null){
			return false;
		}
		this.subList = list;
		return true;
	}
	public List<Subject> getSubjectList(){
		return this.subList;
	}
	public Subject getSubject(int subjectIndex){
		return this.subList.get(subjectIndex);
	}
}